package com.example.userservice.feign;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient(name = "Permission-Service", path = "/permission")
public interface UserServiceFeignClient {
    @GetMapping("/bindDefaultRole")
    void bindDefaultRole(@RequestParam("userId") Long id);

    @GetMapping("/getUserRoleCode")
    String getUserRoleCode(@RequestParam("userId") Long id);

    @GetMapping("/upgradeToAdmin")
    void upgradeToAdmin(@RequestParam("userId") Long id);

    @GetMapping("/downgradeToUser")
    void downgradeToUser(@RequestParam("userId") Long id);
}
